import request from '@/utils/request'

// 查询数据大屏列表
export function listFconfig(query) {
  return request({
    url: '/allocation/fconfig/list',
    method: 'get',
    params: query
  })
}

// 查询数据大屏详细
export function getFconfig(id) {
  return request({
    url: '/allocation/fconfig/' + id,
    method: 'get'
  })
}

// 新增数据大屏
export function addFconfig(data) {
  return request({
    url: '/allocation/fconfig',
    method: 'post',
    data: data
  })
}

// 修改数据大屏
export function updateFconfig(data) {
  return request({
    url: '/allocation/fconfig',
    method: 'put',
    data: data
  })
}

// 删除数据大屏
export function delFconfig(id) {
  return request({
    url: '/allocation/fconfig/' + id,
    method: 'delete'
  })
}

// 消息状态修改
export function changeNoticeStatus(id, configType) {
  const data = {
    id,
    configType
  }
  return request({
    url: '/allocation/poster/changeStatus',
    method: 'put',
    data: data
  })
}
